package com.centaline.androidsalesblog.api.sale;

import com.centaline.androidsalesblog.api.SaleApi;
import com.centaline.androidsalesblog.model.responseobject.RegionPostRo;
import com.centanet.framework.interfaces.IResponseListener;

/**
 * 租售小区房源数量
 * Created by guilin on 16/2/16.
 */
public class RegionPosts3Api extends SaleApi<RegionPostRo> {

    private String postType;
    private String price = "0";
    private String area = "0";
    private String room = "0";
    private String minInputPrice = "";
    private String maxInputPrice = "";

    public RegionPosts3Api(Class<?> tag, Class<RegionPostRo> aClass, IResponseListener<RegionPostRo> iResponseListener) {
        super(tag, aClass, iResponseListener);
    }

    public void setPostType(String postType) {
        this.postType = postType;
    }

    public void setPrice(String price) {
        this.price = price;
    }

    public void setArea(String area) {
        this.area = area;
    }

    public void setRoom(String room) {
        this.room = room;
    }

    public void setMinInputPrice(String minInputPrice) {
        this.minInputPrice = minInputPrice;
    }

    public void setMaxInputPrice(String maxInputPrice) {
        this.maxInputPrice = maxInputPrice;
    }

    @Override
    protected void setParams() {
        putParams("id", 0);
        putParams("level", 0);
        putParams("postType", postType);
        putStringParams("price", price);
        putStringParams("area", area);
        putStringParams("room", room);
        putParams("minInputPrice", minInputPrice);
        putParams("maxInputPrice", maxInputPrice);
    }

    @Override
    protected String getPath() {
        return "RegionPosts";
    }
}
